<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>找回密码</title>
	<meta name="viewport" content="initial-scale=1, maximum-scale=1">
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
	<link rel="stylesheet" href="//g.alicdn.com/msui/sm/0.6.2/css/sm.css">
	<!--如果你用到了拓展包中的组件，还需要引用下面两个-->
	<link rel="stylesheet" href="//g.alicdn.com/msui/sm/0.6.2/css/sm-extend.css">
	<link rel="stylesheet" href="{{asset('/css/mobile/common_web.css')}}">
	<link rel="stylesheet" href="{{asset('/css/mobile/amend_password.css')}}">
</head>
<body>
<div class="page-group">
	<!-- 单个page ,第一个.page默认被展示-->
	<div class="page">
		<!-- 标题栏 -->
		<header class="bar bar-nav" style="background:#24314D;color:#fff;height:3rem;line-height:3rem;">
			<a  href="{{url('/admin/person')}}" class="icon icon-left pull-left external" style="font-size:1.4rem;color:#fff;line-height:2rem;"></a>
			<h1 class="title" style="color:#fff;line-height:3rem;">找回密码</h1>
		</header>

		<!-- 工具栏 -->
		<nav class="bar bar-tab" style="background:#fff;">
			<a class="tab-item external" href="{{url('/admin/home')}}">
				<i class="icon iconfont">&#xe649;</i>
				<span class="tab-label">首页</span>
			</a>
			<a class="tab-item external active" href="{{url('/admin/person')}}">
				<i class="icon iconfont">&#xe648;</i>
				<span class="tab-label">个人设置</span>
			</a>
		</nav>

		<!-- 这里是页面内容区 -->
		<div class="content">
			<div class="list-block">
				<form action="{{url('admin/findPassword')}}" method="post">
					{{csrf_field()}}
					<ul>
						<!-- Text inputs -->
						<li>
							<div class="item-content">
								<div class="item-inner">
									<div class="item-title label">注册手机号：</div>
									<div class="item-input">
										<input type="text" name="phone" id="phone" placeholder="请输入手机号" required minlength="11" maxlength="11">
									</div>
								</div>
							</div>
						</li>
						<li>
							<div class="item-content">
								<div class="item-inner">
									<div class="item-title label">验证码：</div>
									<div class="item-input">
										<input type="password" name="code" placeholder="请输入验证码" required style="width:90%;">
									</div>
									<div>
										<button type="button" onclick="aliSmsCode()" class="button button-big com_btn code save" style="height:3rem;color:#fff;transform: translateY(9%);width:100%;border:none;">获取验证码 </button>
									</div>
								</div>
							</div>
						</li>
						<li>
							<div class="item-content">
								<div class="item-inner">
									<div class="item-title label">输入新密码：</div>
									<div class="item-input">
										<input type="password" placeholder="请输入密码" name="new_password" required>
									</div>
								</div>
							</div>
						</li>
						<li>
							<div class="item-content">
								<div class="item-inner">
									<div class="item-title label">确认新密码：</div>
									<div class="item-input">
										<input type="password" placeholder="请确认密码" name="check_password" required>
									</div>
								</div>
							</div>
						</li>
					</ul>
					<div  style="text-align: center;"><button type="submit" class="open-tabs-modal button button-big btn button-round save" style="font-size:1.3rem;font-weight: 700;height:3rem;margin:1rem 0;">保 存 密 码</button></div>
				</form>
			</div>
		</div>
	</div>
</div>
</body>

<script type='text/javascript' src='//g.alicdn.com/sj/lib/zepto/zepto.js' charset='utf-8'></script>
<script type='text/javascript' src='//g.alicdn.com/msui/sm/0.6.2/js/sm.js' charset='utf-8'></script>
<script type='text/javascript' src='//g.alicdn.com/msui/sm/0.6.2/js/sm-extend.js' charset='utf-8'></script>
<script type="text/javascript" src="//g.alicdn.com/msui/sm/0.6.2/js/sm-city-picker.min.js" charset="utf-8"></script>
<script>$.init()</script>
<script>
    localStorage.url = '{{url('/admin/mobileLogin')}}';
    if ("{{$status}}" == 1) {
        $.modal({
            text: '<div class="tabs">'+
                '<div class="tab active" id="tab1">' +
                '<div>\n' +
                '\t\t<h1>修改成功</h1>\n' +
                '\t\t<p style="text-align: center;">您已修改了密码，请使用新密码重新登录！</p>\n' +
                '\t\t<div style="text-align:center;margin-top:1rem;">\n' +
                '\t\t</div>\n' +
                '\t</div></div>'+
                '</div>',
            buttons: [
                {
                    text: '<form action="{{url('admin/mobileLogin')}}" method="get"><button type="submit">确定</button></form>',
                    // text: '<a href="/admin/home" style="border:none;"><button type="button">确定</button></a>',
                    bold: true
                },
            ]
        });
	}
    function aliSmsCode(){
        var phone = $('#phone').val();
        $.post('{{url('admin/aliSmsCode')}}',{'phone': phone,},function(){

        });
    }
</script>
</html>

